
public class Main {

	public static void main(String[] args) {
		/*inserting 505
inserting 399
inserting 390
inserting 102
inserting 318
inserting 97
inserting 68*/
		int[] array = new int[] {505, 399, 390, 102, 318, 97, 68};
		Heap h = new Heap();
		for (int i : array) {
			h.insert(i);
			System.out.println(h.toString());
			if (!h.contains(i))
				System.out.println("does not contain " + i);
		}
		
		System.out.println("\n\n\n\n");
		for (int i = 0; i < array.length; i++) {
			System.out.println("deleting " + h.getMin());
			h.deleteMin();
			System.out.println(h.toString());
			
		}
	}
	
//	public static void main(String[] args) {
//		Heap h = new Heap();
//		h.insert(5);
//		System.out.println(h.getMin());
//	}
}
